Information processing apparatus, and print control method

ABSTRACT

To reduce the workload involved in rearranging and printing a Web page in a desired layout, style sheets for realizing desired print layouts are saved in association with the URLs of Web pages, and when subsequently printing a Web page having the same domain name or a similar URL, a print layout to which a saved style sheet has been applied is presented as a candidate, and applied when printing the Web page.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to an information processing apparatus anda print control method, and more particularly to an informationprocessing apparatus and method for printing, in a desired layout, a Webpage constituted by a plurality of parts such as with a multi-columnlayout.

2. Description of the Related Art

FIG. 1 shows an example of a Web page with a typical multi-columnstructure. In most cases, a main content P10, such as the body of a newsarticle or a blog article (entries), is arranged in the center.Secondary content such as a header P20, a navigation bar P30 (internaland external site links) and banner advertisements P40 are arranged asparts (objects) around the main content. This secondary Web content P20to P40 is necessary for easily moving between displayed Web pages, forinstance, and is not really necessary in the case of reading a Web pageprinted on paper.

Thus, Web site designers have heretofore been recommended to provide Websites with “style sheets for printing” that eliminate parts such asnavigation bars and advertisements, separately from the pages fordisplay. By using these style sheets, printed material from whichnavigation bars, advertisements and the like has been removed can beobtained, as shown in FIG. 2. Here, a print style sheet is layoutinformation for converting a page for display such as in FIG. 1 to alayout such as the page for printing in FIG. 2, and, specifically,contains instructions that result in only the main content P10 beingprinted the full width of the page.

However, since the work involved in providing style sheets for printingfalls on Web site designers, there are many Web sites with respect towhich style sheets have not been prepared, and printing can only beperformed in the same layout as the pages for display. Also, sinceadvertisements, internal and external site links and the like aresometimes arranged on the pages for printing, it is not necessarily thecase that all pages for printing will be in a layout desired by the userwho actually performs the printing.

Techniques such as shown in Japanese Patent Laid-Open No. 11-250054 andin HP Inkjet Printers—Using Smart Web Printing Software ([online,Japanese only], updated August 2008, Hewlett-Packard Japan Ltd., viewedDec. 25, 2008, URL:http://h10025.www1.hp.com/ewfrf/ws/document?1c=ja&cc=jp&docuname=c01418497)have been proposed in order to alleviate this shortcoming with pages forprinting. In Japanese Patent Laid-Open No. 11-250054, a technique forextracting and rearranging a plurality of objects constituting a Webpage and generating a new Web page in a free layout is discussed. Also,HP Inkjet Printers—Using Smart Web Printing Software is an example ofsoftware that has actually been developed. A page to be printed can becreated with the feel of a scrapbook by using this software to copy andpaste portions of a Web page that the user wants to print.

Using the techniques disclosed in Japanese Patent Laid-Open No.11-250054 and HP Inkjet Printers—Using Smart Web Printing Softwareenables a desired print layout to be realized by rearranging a Web page.However, the user has to carry out the tedious process of rearrangingthe objects forming the print target, whenever he or she wants to printa Web page. For example, in the case where a user frequently visits agiven news site and frequently prints pages thereof, he or she mustperform the process of cutting and rearranging only the articles whileeliminating advertisements and the like every time, despite this processbeing predictable. While this is a standard process, it is difficult toautomate the rearranging process with conventional methods, since thelength of articles varies even within the same site.

SUMMARY OF THE INVENTION

The present invention has been made in consideration of the prior artdescribed above, and provides an information processing apparatus and aprint control method that are able to reduce the hassle involved in theprocess of rearranging a Web page for printing, and enable a Web page tobe easily printed in a desired layout.

In order to solve the above problem, the present invention has thefollowing configuration.

According to an aspect of the present invention, an informationprocessing apparatus for printing a Web page constituted by a pluralityof parts, comprises: a selecting unit, configured to select a part to beprinted from parts constituting a Web page targeted for printing; acreating unit, configured to create a style sheet for printing on whichthe part selected by the selecting unit has been rearranged; a storageunit, configured to store the style sheet in association with an addressof the print target Web page; an extracting unit, configured to, in acase where a Web page newly targeted for printing is displayed, extracta style sheet to be used for the new Web page from one or more stylesheets stored by the storage unit, based on an address of the new Webpage; and a generating unit, configured to generate a print page basedon the style sheet extracted by the extracting unit and the new Webpage.

According to the present invention, the process of printing a Web pagein a layout desired by a user can be realized without performingrearranging every time printing is performed.

Further features of the present invention will become apparent from thefollowing description of exemplary embodiments (with reference to theattached drawings).

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows an example multi-column Web page.

FIG. 2 shows an example page for printing.

FIG. 3 is a block diagram showing a configuration of an entire systemaccording to a first embodiment of the present invention.

FIG. 4 is a block diagram showing an internal system of a printcontroller 105.

FIG. 5 shows an example of a print preview window.

FIGS. 6A and 6B are flowcharts showing a processing flow of previewdisplay, re-layout and printing.

FIG. 7 is a schematic view showing a process of erasing unnecessaryparts and re-laying out using a style sheet.

FIG. 8 shows an example style sheet.

FIG. 9 shows an example style sheet DB.

FIG. 10 shows an example of a print preview window on which candidatethumbnails are displayed.

FIGS. 11A and 11B are flowcharts showing a flow of a process ofselecting and printing a candidate.

FIG. 12 is a flowchart showing a processing flow according to a secondembodiment of the present invention.

FIG. 13 is a conceptual view of a user forum style sheet DB according toa third embodiment of the present invention.

FIG. 14 is a conceptual view of a process of automatically performinglayout from a page title according to a fourth embodiment of the presentinvention.

FIG. 15 is a flowchart showing a processing flow of automaticallyperforming layout from a page title.

FIG. 16 is a block diagram showing a system configuration according to afifth embodiment of the present invention.

FIG. 17 is a block diagram showing a hardware configuration of acomputer.

DESCRIPTION OF THE EMBODIMENTS Embodiment 1 FIG. 3 Description of WebBrowser

FIG. 3 illustrates an example configuration of an entire systemincluding an external environment of a Web page printing apparatusaccording to a first embodiment of the present invention. In FIG. 3, acomputer 1 is connected to the Internet 2 and a printer 3 by a networkinterface such as an Ethernet®. A Web browser 10 is an applicationprogram that operates on an operating system of the computer 1, that is,an information processing apparatus. The Web browser 10 accesses a Webserver specified by a designated address, that is, an URL, and displays,as an image, Web content such as HTML data or image data provided fromthe Web server. A network controller 101, which is one of the componentsconstituting the Web browser 10, performs processing such as Web contentacquisition from the Internet 2. A page saving unit 102, which issimilarly one of the internal components of the Web browser 10, savesWeb content acquired by the network controller 101 to a main storageapparatus such as a memory or an external storage apparatus such as ahard disk. The page saving unit 102 also extracts saved Web content inresponse to a request from an external component.

A page display unit 103 extracts a Web page saved by the page savingunit 102, and displays the Web page in a window after interpretingdescription therein written in HTML language. Also, the page displayunit 103, in the case where a style sheet is designated for the Webpage, displays the Web page after applying the style sheet. An inputcontroller 104 performs processing according to menu commands performedon the Web browser 10 and input with respect to links or buttonsdisplayed on a Web page. In the case where a link on a Web page isclicked, for example, the input controller 104 instructs the networkcontroller 101 to acquire the Web page of that link.

A print controller 105 is a component that performs the main processingof the present invention, and performs processing such as print previewdisplay, layout modification, and printing of a Web page. The printcontroller 105 may be incorporated as part of the Web browser 10 inadvance, or may be a plug-in that can be added later. The internalsystem of the print controller 105 will be discussed in detail later.

A graphics engine 11 is a component that controls a rendering process ofthe operating system, and performs a role of mediating renderingcommands from a printing unit. A printer driver 12 is software thatreceives rendering commands mediated by the graphics engine 11, convertsthe rendering commands to PDL data that can be interpreted by theprinter 3, and outputs the PDL data. The printer 3 prints the PDL dataoutput by the printer driver 12. Note that an example in which theprinter 3 is a digital multifunction peripheral connected to a computerby a network such as an Ethernet is shown here. However, the presentinvention is not limited to this, and may be an inkjet printer connectedby a USB interface.

FIG. 17: Hardware Configuration of Computer

FIG. 17 is a block configuration diagram representing an internal systemof the computer 1, which is a generic computer. A CPU 1701 performscontrol of the entire apparatus in accordance with programs stored in aROM 1702, a RAM 1703 or an external storage apparatus 1705. Theseprograms include an operating system, a Web browser, and plug-insoftware thereof. The RAM 1703 is used as a work area for when the CPU1701 performs various processing. The external storage apparatus 1705stores data and programs such as an operating system (OS), applicationsoftware, and printer driver software. A keyboard 1704 or an inputdevice such a mouse (not shown) is a device for a user to providevarious instructions. A network I/F 1706 and a printer I/F 1707 areinterfaces for connecting to a printer 20 via an Ethernet or a dedicatedinterface, and sending and receiving data. A monitor I/F 1708 is aninterface for connecting to a monitor and transferring display data.Also, reference numeral 1709 is a common data bus.

FIG. 4: Detailed Description of Print Controller 105

FIG. 4 is a block configuration diagram representing an internal systemof the print controller 105. A preview window controller 21 plays a roleof managing input and output with respect to a print preview window. Astyle sheet generating unit 22 is a component that generates a stylesheet for realizing a desired print layout in response to a request fromthe preview window controller 21. A preview window display unit 23generates and displays a print preview window, a rearranged printpreview window, thumbnail images serving as print layout candidates, andthe like. Displayed windows will be discussed in detail later. A stylesheet search unit 24 searches for and acquires style sheet data from astyle sheet DB (database) 26 and a user forum style sheet DB 27. Aprinting unit 25 is a component that applies a style sheet to a Web pageand performs a printing process via a graphics engine. The style sheetDB 26 is a database that resides on a hard disk in the computer 1, andis for saving style sheets. Also, the user forum style sheet DB 27 is adatabase located in a server on the Internet 2 accessible via thenetwork controller 101. Style sheets generated by a user are saved inassociation with information such as the URLs of printed Web pages andcreation dates/times in both the databases 26 and 27. The record formatin the databases and the role played by the databases will be discussedlater.

FIG. 5: Description of Screenshot of Print Preview Window

FIG. 5 shows an example of a print preview window displayed by the printcontroller 105. Here, assume the case where an easily viewable page forprinting such as FIG. 2 has not been prepared with respect to a Web pagesuch as shown in FIG. 1. Hereinafter, an operation method for when theuser performs printing after rearranging an existing print layout thatis not easily viewable such as FIG. 1 into a print layout that is easilyviewable such as FIG. 2 will be described.

The input controller 104 of the Web browser 10 displays a print previewwindow 31, in the case where an instruction to display a print previewwindow of the Web page currently being displayed is received. The printpreview window 31 is divided into the two areas of the left side and theright side, and an original preview image 32 and a re-laid out previewimage 33 are respectively displayed on the left side and the right side.The original preview image is a preview image of the case where thedisplayed Web page is printed without modification. In contrast, there-laid out preview image is a preview image of the case where the Webpage is rearranged according to the user's preference. In the example inFIG. 5, the re-laid out preview image 33 is displayed on the right side,but in an initial state, a blank preview image, that is, a state wherenothing is to be printed is displayed.

Here, with the selection of an area targeted for printing, a portionthat the user wants to print from the original preview image 32, such asan area 34 on the Web page, for example, is selected by the user with amouse cursor or the like. Note that an area on a Web page as referred tohere is a unit of description written using an HTML element, rather thanmerely referring to an area that is displayed, and, hereinafter, mayalso be called a part or an object. While this will be discussed indetail later with reference to FIG. 7, a part in the present example isan element or a group of elements organized using “elements fororganizing elements”.

The rearrangement of a part thus selected (selected part) is performedby dragging and dropping the selected part (e.g., area 34) in thepreview image 33 on the right side with a mouse.

While the various parts of a Web page are displayed in the preview image32, any part can be selected and dragged and dropped in the previewimage 33 if displayed in the preview image 32. Once the selected parthas been dragged and dropped in the preview image 33, a copy 35 of theselected part is created and displayed on the preview image 33. Thispreview image 33 is set as the print target.

Further, the copy 35 of the selected part can be resized, by the usergrabbing and dragging a frame 351 (displayed with a dotted line in FIG.5) of the copy 35 of the selected part with a mouse cursor, for example.In the case where text is included in the selected part 34, and the textdoes not fit on one line and is returned in accordance with the width ofthe frame, the return position shifts in accordance with an increase inthe width of the copy 35 of the selected part. Layout can thereby beperformed so as to display a large number of characters on one line.Further, the copy 35 of the selected part can also be repositioned byholding the middle, for example, of the copy 35 of the selected part anddragging the copy around in the image 33, for example.

Note that because the operations for selecting and rearranging parts canbe repeated any number of times, it is also possible to print thepreview image 33 after arranging a plurality of parts therein. Selectedparts can also be deleted from the preview image 33. When the printlayout has been decided, the user is able to print the preview image 33from the printer 3 by pressing a print button 36.

FIG. 7: Schematic View of Erasing Unnecessary Parts and PerformingRe-Layout Using a Style Sheet

Next, the operations by the user illustrated in FIG. 5 will be describedin association with corresponding processing in the print controller105. Before that, firstly a style sheet will be described. FIG. 7 is aschematic view representing the mechanism that enables a part that theuser wants to print to be selected and rearranged.

A pre-rearrangement Web page 41 is constituted by parts 42 to 45. Withthe HTML language, “elements for organizing elements” such as <div/> and<span/> are defined, and an ID attribute (unique identifier of eachpart) can be assigned to each element. A “part” in the presentembodiment refers to an element or a group of elements organized bythese “elements for organizing elements”. In FIG. 7, parts having theIDs “header”, “navigation”, “sponsored”, “contents” are included. Theseparts each include elements describing the designation of text andimages, the arrangement thereof, and the like. The ID attributes ofthese <div/> elements (and also <span/> elements that are not shown) canbe referred to from a style sheet or a script associated with the Webpage, and are used as part names, so to speak, constituting the Webpage. A Web page 41 in FIG. 7 is constituted by referring to the IDattributes “header”, “navigation”, “sponsored”, “contents” of the <div/>elements in this way. A rearranged Web page 46 to which a style sheethas been applied is configured so as to display only the <div/> elementof the ID attribute “contents” out of these ID attributes.

FIG. 8: Example Style Sheet

FIG. 8 shows an example style sheet. A style sheet is a format forcontrolling the appearance of the background, text and layout of a Webpage. While the details of the format will be omitted, the example inFIG. 8 is an example style sheet 48 for realizing the Web page 46 inFIG. 7. With the style sheet 48, the elements having the IDs “header”,“navigation” and “sponsored” are hidden using the description{display:none;}. On the other hand, the element having the ID “contents”represents, with the description {width:100%}, an instruction relatingto display and layout, such that the width of the part is set to 100%with respect to the width of the area in which the part is arranged.Once the style sheet 48 of the present example has been associated withthe Web page 41 in FIG. 7, parts 42, 43 and 45 having the IDs “header”,“navigation” and “sponsored” will be hidden. On the other hand, the Webpage is converted to a layout in which a part 47 having the ID“contents”, which is designated to be displayed at 100%, occupies thefull width of the page. As a result, a new Web page 46 whose parts havebeen rearranged is generated as an image and displayed. In this way,using a style sheet enables the appearance to be modified withoutmodifying the original Web page.

FIGS. 6A and 6B: Processing Flow of Preview Display, Re-Layout, andPrinting

Next, the operations by a user illustrated in FIG. 5 will be describedusing FIGS. 6A and 6B, in order to associate these operations withcorresponding processing in the print controller 105. FIGS. 6A and 6Bare flowcharts showing a processing flow of preview display, re-layoutand printing by the print controller 105. Note that the flowcharts ofthe present application are realized by the CPU 1701 in FIG. 17executing associated programs. Also, the procedure in FIGS. 6A and 6B isstarted in a state where the Web browser 10 has already been executed, adesignated Web page has been acquired from a Web server, saved anddisplayed, and the print controller 105 is waiting for input.

Firstly, in step S101, the preview window controller 21 receives inputof a command to display a print preview of the Web page currently beingdisplayed on the page display unit 103. This command is input inresponse to an instruction from the user, for example. Next, in stepS102, the preview window controller 21 acquires the data of thecurrently displayed Web page from the page saving unit 102, andtransmits the data to the preview window display unit 23. Next, in stepS103, the preview window display unit 23 generates and displays theprint preview window 31.

Next, in step S104, the preview window display unit 23 interprets theWeb page data acquired from the page saving unit 102, and displays aprint preview image 32 tailored to the Web page data on the left side ofthe print preview window 31. In step S105, the preview window displayunit 23 displays a blank preview image, which is the initial state ofthe re-laid out preview image 33, on the right side of the print previewwindow 31. Next, in step S106, the preview window controller 21 waitsfor input of an operation by the user, and, if input is received,branches according to the instruction content. That is, the previewwindow controller 21 receives a parts rearrangement instructionresulting from a drag-and-drop operation by the user, determines thecontent of the received instruction, and branches according to thecontent. The preview window controller 21 branches to step S107 if it isdetected that a part on the preview image 32 that the user wants toprint has been selected by the user using a mouse, for instance, anddragged and dropped in the preview image 33. On the other hand, thepreview window controller 21 branches to step S120 if input to the printbutton 36 is detected.

Once a rearrangement instruction has thus been received, the part thathas been dragged and dropped is displayed in the preview image 33 on theright side, as a result of the next steps S107 to S113. In step S107,the preview window controller 21 analyzes the description of the elementwritten in HTML language in the selected part that has been dragged anddropped, and acquires the ID of the part included therein. With thedrag-and-drop function provided by the operating system, various formatsare supported in terms of the format of objects to be dragged, and theHTML format is supported as one of those. Once a part (object) in HTMLformat has been dragged and dropped, it is possible, in the window inwhich the part was dropped, to acquire a source code of the HTMLlanguage of the part.

The preview window controller 21 analyzes the contents of the HTMLlanguage thus dropped, and extracts the ID attribute of the <div/> or<span/> element. In the case where a plurality of IDs are located in theHTML source code of the selected part, these are all acquired. Next, instep S108, the style sheet generating unit 22 receives the ID acquiredat step S107 from the preview window controller 21, and adds the ID to adisplay target ID list. The display target ID list is a list held inmemory by the preview window controller 21, and is used for managinginformation on parts displayed in the rearranged print preview image 33on the right side.

Because the number of parts displayed in the preview image 33 increasesas the result of user operations, the display target ID list is updatedeach time. Next, in step S109, the style sheet generating unit 22 thistime analyzes the currently displayed Web page acquired from the pagesaving unit 102, and acquires the IDs of all parts. From the next stepsS110 to S112, the processing is repeatedly performed for all parts inthe Web page whose IDs were acquired at step S109.

In step S110, the style sheet generating unit 22 focuses sequentially onthe IDs of the parts acquired from the Web page at step S109, anddetermines whether the ID of the part focused on exists in the displaytarget ID list. If the ID of the part focused on does exist in the list,the processing proceeds to step S111, and if the ID does not exist inthe list, the processing proceeds to step S112. In step S112, the stylesheet generating unit 22 writes the element (i.e., part) having that IDinto the style sheet so as to be hidden. Specifically, the style sheetgenerating unit 22 adds description designating a display attribute suchas “id{display:none;}” to the style sheet with respect to the elementhaving that ID. A style sheet as referred to here is character stringinformation held in memory by the style sheet generating unit 22, and isupdated by steps S111 and S112 and by step S116 (discussed later). Thecontent thereof is as illustrated in FIG. 8. Hereinafter, this stylesheet in memory will be assumed to be the style sheet 48, along thelines of the schematic view in FIG. 8. On the other hand, in step S111,the style sheet generating unit 22 writes the element having that IDinto the style sheet 48 so as to be displayed. In the case where anelement is to be displayed, it is not necessary to explicitly specify adisplay attribute, unlike hiding an element, but because of thepossibility of a display attribute being designated at step S116, thestyle sheet generating unit 22 writes only the ID into the style sheet48, such as “id{ }”, without providing a display attribute.

When steps S110 to S112 have been executed with regard to the IDs of allparts in the Web page, the processing proceeds to step S113. In stepS113, the preview window controller 21 generates a print layout image byapplying the style sheet 48 generated by the style sheet generating unit22 in steps S111 to S112 to the Web page acquired at step S109, anddisplays the print layout image as the image 33. Here, with the printlayout displayed in the preview image 33, parts that have not beenselected and dropped at step S106 will all be hidden by the style sheet.

Next, if the Web part indicated by reference numeral 47 in the schematicview of FIG. 7 is repositioned or resized as a result of the userrepositioning or resizing the window, the preview window controller 21,in step S114, detects the position or the size modified according to theoperation. That is, the preview window controller 21 receivesdesignation of the modified position or size. Next, in step S115, thepreview window controller 21 converts the position or size on the windowacquired at S114 to a position or size on the page. Specifically, thepreview window controller 21 calculates the actual size or position onthe page, from the relative positional coordinates in the preview image33 representing the laid out page and the ratio of the size of thewindow of the preview image 33 and the actual size of the page. Next, instep S116, the style sheet generating unit 22 reflects information onthe position or the size calculated at step S115 in a position or a sizeserving as a display attribute value of the ID of the part in the stylesheet 48. Specifically, assume, for example, that an operation has beenperformed to move the position of the selected part to a position (15pixels, 15 pixels) from the top left edge of the page, and make thehorizontal width of the size the full width of the page. In this case,the preview window controller 21 sets the display attribute of an id1corresponding to the part of the style sheet 48 to a value such as thefollowing, for example.

id1{position:absolute;top:15px;left:15px;width:100%}

This is description that applies a modification in position and sizecorresponding to the above operation to the part.

Next, in step S117, the preview window display unit 23 again generates aprint layout image by applying the style sheet 48 updated at step S116to the Web page acquired at step S109, and displays the print layoutimage as the preview image 33. By reflecting the modification inposition and size on the window in the style sheet and applying theupdated style sheet to the Web page in this way, a print preview imagethat has been re-laid out without changing the content of the Web pagecan be obtained. After step S117, the processing returns to step S106,and the preview window controller 21 receives input of an operation bythe user.

If input to the print button is detected at step S106, the printing unit25, in step S120, prints the Web page to which the style sheet 48obtained at step S117 has been applied, or prints a blank sheet in thecase where no rearrangement operation has been performed. Normalbrowsers are equipped with a technique for printing a Web page, and thiscan be utilized without modification. Note that in order to prohibitprinting of a blank sheet here, the preview window controller 21 canalso be configured not to accept input to the print button in step S106in the case of a blank sheet.

Finally, in step S121, the style sheet generating unit 22 saves thestyle sheet 48 generated at step S117 in the style sheet DB 26 inassociation with the URL of the printed Web page.

Note that at step S106 of FIG. 6A, it was disclosed that the only choicewas between the rearrangement operation and the print operation, butother operations, such as cancellation of an operation, can of course beaccepted. In that case, processing according to the operation can ofcourse be executed.

According to the present embodiment as described above, the layout of aWeb page can be easily modified.

FIG. 9: Example Style Sheet DB

FIG. 9 shows example records saved in the style sheet DB 26. The stylesheet DB 26 includes “URL”, “Style Sheet”, “Creation Date/Time”, and“Usage Frequency” as the fields of records. The URLs and style sheetsare, as abovementioned at step S121, respectively the URLs of printtarget Web pages and style sheets 48 for realizing layouts in whichparts to be printed have been selected and rearranged by the userhimself or herself. The date and time at which step S121 was executed issaved as the creation date/time. As will be mentioned later with regardto the usage frequency, the number of times that a saved style sheet isused in printing the Web pages of URLs other than the URL saved inassociation with the style sheet is saved in this field.

This style sheet DB 26 is utilized when printing a Web page with thesame or similar URL, in a Web site that has been printed with theprocedures of steps S101 to S121. In other words, reducing the operationload of the user is realized by storing created style sheets so as to beusable when printing other Web pages.

Embodiment 2

Next, an embodiment 2 that expands on embodiment 1 will be described.Note that description of points in common with embodiment 1 will beomitted. The present embodiment is intended to enable re-layout whenprinting a Web page to be more easily performed, by effectively reusingstyle sheets registered in the style sheet DB 26. More specifically, astyle sheet having an association with the displayed Web page, out ofthe style sheets registered in the style sheet DB 26, is displayed on aprint preview window as a thumbnail. A style sheet having an associationis a style sheet that was used for printing a Web page specified by aURL that includes the same server name, that is, the same domain name asthe Web page that the user is trying to print. The reason for this isthat because an ID is assigned to each part in a Web page as shown inFIG. 7, and the creator will be the same if the Web pages belong to thesame Web site, the naming rules of these IDs will often be the same. Forexample, with most news sites, the body, title, photographs and the likeof news articles will be different for each Web page, but it is highlylikely that they will all be configured by the same template, that is,by Web parts assigned with the same IDs. According, if in the Web pagesare in the same Web site, it is highly likely that the layout can bemodified in the same way, even if a style sheet corresponding to a giveWeb page is applied to a different Web page. Utilizing of this fact,style sheets and Web pages are associated by domain name. Then, byselecting one of the candidate thumbnails, a layout that uses a stylesheet can be realized, without selecting or rearranging the parts of theWeb page. Hereinafter, the processing and the like of the presentembodiment will be described.

FIG. 10: Description of Screenshot of Window Displaying Layout CandidateThumbnails

A window 31 in FIG. 10 is an example window where the user is able tochoose and print a favored layout from among the candidates. Here,assume that the user has opened and is trying to print a Web page in thesame Web site but with a different URL to the Web page printed in FIG.5, that is, a Web page in which the domain name portion of the URL isthe same. The role and arrangement of user interfaces such as theoriginal preview image 32 on the left side, the print preview image 33that the user would like to print on the right side and the print button36 are unchanged from the example window shown in FIG. 5. A differencewith FIG. 5 lies with candidate thumbnails 49 displayed at an upper partof the window. Candidate thumbnails 49 are displayed in the case wherepages in the same Web site as the page that the user is currently tryingto print have previously been printed.

The candidate thumbnails each correspond to a previous style sheet usedin printing a page in the same Web site. Printing can be performed afterapplying a style sheet corresponding to the selected thumbnail to thecurrent Web page by selecting one of these candidate thumbnails. Thecandidate thumbnails are arranged in order of decreasing usage frequencyfrom the left, and if there are a plurality of candidates, the printpreview image 33 is displayed as a result of having automaticallyselected and applied the style sheet on the far left with the highestusage frequency. In other words, the style sheets are displayed in orderfrom the style sheet with the highest priority level. The user is ableto directly press the print button 36 and print the print preview image33 if he or she likes that print layout, and is also able to select adifferent candidate if he or she does not like that print layout. Ofcourse, in order to make a new print layout that is completelydifferent, the user may perform rearrangement in line with the flowshown in FIGS. 6A and 6B. For that purpose, a blank thumbnail may beadded to the thumbnails displayed as candidates, or a button or the likefor deleting all of the parts of the preview image 33 may be provided.

The work involved in rearranging the layout of a Web page is more orless predicable, such as deleting advertisements and navigation bars,and adjusting the width of the body, and the user's workload can bereduced by automatically saving and reusing such work content as stylesheets. Next, the flow of the abovementioned reuse of style sheets willbe described using FIGS. 11A and 11B.

FIGS. 11A and 11B: Flow of Layout Candidate Application and SelectionProcess

FIGS. 11A and 11B are flowcharts showing a flow of applying and printinga previous print layout using the style sheet DB 26. The flow fromdisplay of the preview window 31 to display of the default print previewimage 32 on the left side performed by the preview window controller 21from steps S201 to S204 is similar to steps S101 to S104.

In step S205, the style sheet search unit 24 acquires the URL of the Webpage that the user is trying to print. Next, in step S206, the stylesheet search unit 24 extracts the domain name portion from the URLacquired in step S205. For example, if the URL that the user is tryingto print is “http://------.com/article/20081019aaa”, the extracteddomain name will be “------.com”. In the next steps S207 to S208, thestyle sheet search unit 24 extracts the entries from the style sheet DB26 one by one, and perform processing on each entry.

In step S207, the style sheet search unit 24 judges whether the URL ofthe entry extracted from the style sheet DB 26 includes the domain nameportion extracted at step S206. For example, assuming that the URL thatthe user is trying to print is “http://------.com/article/20081020bbb”,and that the URL of an entry saved in the style sheet DB 26 is“http://------.com/article/20081019aaa”, the URLs will be different oncomparison, but because the domain name portions are the same oncomparison, the URL will be judged to include the same domain nameportion. If the URL does include the same domain name, the processingproceeds to step S208, and if the URL does not include the same domainname, no further processing is performed on that entry, and the nextentry is extracted, before the processing again proceeds to step S207.

Next, in step S208, the preview window controller 21 applies the stylesheet of the entry to the print target Web site to create a thumbnailimage to serve as a candidate. A candidate thumbnail image is small ataround one third the size of the preview image 32 or the preview image33, but enables the approximate arrangement of the Web parts to bedistinguished despite being small.

When the above steps S207 and S208 have been performed with regard toall entries in the style sheet DB 26, the processing proceeds to stepS209. Next, in step S209, the preview window display unit 23 determineswhether there are one or more candidate thumbnail images created in stepS208, and if there are, the processing proceeds to step S210. On theother hand, if there are not one or more candidates, the processingproceeds to step S105 illustrated in FIG. 6A, and subsequently becomesthe flow in which the user himself or herself selects and rearranges theprint target Web parts.

If there are one or more candidates, the preview window display unit 23,in step S210, displays the thumbnail images in a position at the toppart 49 of the window, arranged from the left in descending order of the“usage frequency” recorded in the style sheet DB 26. If usagefrequencies are the same, the thumbnail image with the most recent“creation date/time” may be displayed first, for instance. Also, allcandidate thumbnail images, that is, the full number of style sheetsfound to correspond to URLs that have the same domain name may bedisplayed, or a limited number may be displayed, such as the top three.These candidate thumbnails not only represent an overview of thelayouts, but also serve as input means that can be selected by a mouseor a keyboard.

Next, in step S211, the preview window display unit 23 sets thethumbnail furthest to the left side (thumbnail created from the stylesheet used the most number of times) to a state of being selected as thedefault candidate. Further, in step S212, the preview window displayunit 23 generates a print preview image by applying the style sheetselected at step S211 to the Web page, and displays the print previewimage as the print preview image 33 on the right side of the window. Theuser himself or herself is able to switch to a desired layout byconfirming and selecting a candidate thumbnail. However, the user'sworkload can be reduced as a result of the preview window display unit23 performing the selection in advance, because of it being highlylikely that the most used style sheet will be favored by the user.

Next, in step S213, the preview window controller 21 waits for input ofan operation by the user from the input controller 104, and, if input isreceived, determines the operation content thereof. If input of aselection of a different candidate thumbnail from the user is detected,the processing branches to step S214. In step S214, the preview windowdisplay unit 23 generates a print preview image by applying the stylesheet corresponding to the selected candidate thumbnail to the Web page,and displays the print preview image as the print preview image 33 onthe right side of the window. The user is able to repeat step S214 untila favorable layout is found.

Next, in step S215, the preview window controller 21 determines whetherthe operation received at step S213 is input to the print button. Thepreview window controller 21, in the case of detecting input withrespect to the print button 36, branches to step S216. In step S216, theprinting unit 25 performs printing after applying the style sheet lastselected at step S214 to the Web page. In step S217, the style sheetsearch unit 24 increases by one and saves a “usage frequency” counter ofthe entry that includes the style sheet used in printing, and updatesthe style sheet DB 26. If the operation received in step S215 is notinput to the print button, the processing branches to step S106 in FIG.6A. At step S106, the user is further able to edit the laid out previewimage 33.

The chances of the style sheet selected from the candidates being usedthe next time printing is performed thereby increase. Note that in stepS215, the other operations are all determined to be the shifting ofparts, but the present invention is not limited to this, and the otheroperations can be determined with respect also to selection of a blankstyle sheet, cancellation of an operation, or the like, for example. Ofcourse, if those operations are performed, processing tailored to thoseoperations is executed.

In the present embodiment as described above, if a Web page in a givenWeb site has been rearranged and printed, it is subsequently possible toautomatically print Web pages in the same Web site in a desired layout,without rearranging those Web pages. Also, if there are a plurality oflayout candidates, a desired layout can be selected and printed fromthose candidates.

Embodiment 3

Next, the processing of a Web page printing apparatus according to anembodiment 3 of the present invention will be described using theflowchart of FIG. 12.

FIG. 12: Processing Flow of Candidate Search by URL Comparison

In embodiments 1 and 2, whether the domain names of URLs are the same isused as a basis for applying a style sheet used in the print layoutrearrangement of a given Web page to a different Web page. However, itis possible that, even with the same news site, for example, originallayouts will differ greatly between the pages of individual newsarticles and gallery pages in which news photographs are collected orthe pages of columns, and that the types of parts constituting Web pageswill also differ. In such cases, a way of picking a style sheet thatbest suits the Web page that the user is trying to print, from amongstyle sheets associated with the same domain, is required.

In view of this, in the present embodiment, means for selecting theoptimum style sheet by comparing URLs in detail will be discussed. Inthe present embodiment, the configuration is unchanged from embodiment2, but the processing from steps S206 of FIG. 11A to S211 of FIG. 11Bdiscussed in embodiment 2 is replaced with processing from steps S301 toS307.

FIG. 12 shows a flowchart representing the processing from steps S301 toS307. The processing of the present embodiment replaces steps S206 inFIG. 11A to S211 in FIG. 11B with these steps S301 to S307.

Firstly, in step S301, the style sheet search unit 24 extracts apathname portion together with the domain name portion of the URL of theWeb page that the user is trying to print, and further extracts one ormore phrases, using slash symbols included in the pathname asdelimiters. For example, in the case where the URL of the Web page is“http://.com/article/20081020bbb”, the domain name portion is“------.com” and the pathname portion is “article/20081020bbb”. Further,when the pathname is broken down using the slash symbols as delimiters,the two phrases “article” and “20081020bbb” are extracted. Note thathereinafter, because the pathname portion, when viewed in terms of thewhole URL, can also be taken as a single phrase partitioned by slashsymbols, the phrases constituting the pathname and the domain nameportion will both be treated as “phrases” without distinguishing betweenthem.

In the next steps S302 to S304, the style sheet search unit 24 extractsthe entries from the style sheet DB 26 one by one, and performsprocessing on each entry. In step S302, the style sheet search unit 24,with reference to the URL of the entry extracted from the style sheet DB26, counts how many of the phrases extracted at step S301 are included,taking the word order into consideration, and stores the number ofmatching phrases in association with the entry. The counting method ofthis step S302 will be described using an example.

For example, in the URL “------.com/photonews/200804” of entry #1 in thestyle sheet DB 26 shown in FIG. 9, firstly the first phrase “------.com”(domain name), is included, but because the remaining phrases “article”and “20081020bbb” are not included, the number of matching phrases is“1”. With the method of counting matching phrases, the counting ends atthe point at which a phrase that does not match appears, because oftaking into consideration the order, namely, first phrase, secondphrase, and so on. Further, with regard to the URL“------.com/article/20080320aaa” of entry #2 as an example, because thetwo phrases “------.com” and “article” are included in order, thematching number is “2”.

Next, in step S303, the style sheet search unit 24 judges whether thenumber of the phrases counted at step S302 is one or more. If one ormore, the processing proceeds to step S304, and if not one or more, nofurther processing is performed on that entry, and the next entry isextracted, before the processing again proceeds to step S302.

In the next step S304, the preview window controller 21 creates athumbnail image to serve as a candidate by applying the style sheet ofthe entry to the Web page. Next, in step S305, the preview windowdisplay unit 23 determines whether there are one or more candidatethumbnail images created in step S304, and if there are, the processingproceeds to step S306. On the other hand, if there are not one or morecandidate thumbnail images, the processing proceeds to step S105illustrated in FIG. 6A, and subsequently becomes the flow in which theuser himself or herself selects and rearranges the print target Webparts, similarly to the first embodiment.

In the case of there being one or more candidates, the preview windowdisplay unit 23, in step S306, reorders the thumbnail images, with thenumber of matching phrases counted at step S303 as a first basis and theusage frequency of entries as a second basis, and displays the thumbnailimages in a position at the top 49 of the window. In embodiment 1,candidates were reordered on the basis of only the usage frequency ofentries, but in embodiment 3, candidates are reordered with preferencegiven more to the number of matching phrases at step S303.

For example, entries #1, #2 and #4 are chosen as candidates with one ormore matching phrases, from among the entries in the style sheet DB 26of FIG. 9. When they are reordered on the basis used in embodiments 1and 2, the order will be entries #1, #4 and #2 in descending order ofusage frequency, but when the entries are reordered in accordance withthe basis of the present embodiment, the order will be entries #2, #1,and #4. The reason being that since the URL of entry #2 out of the threeentries serving as candidates is “http://------.com/article/2008320aaa”,the two phrases “------.com” and “article” match the URL“http://------.com/article/20081020bbb” of the Web page that the user istrying to print. In contrast, because the URLs of entries #1 and #4 haveonly one matching phrase, that is, the domain name, the priority ofthese entries is lower than entry #2. In the case where the number ofmatching phrases is the same, as with entries #1 and #4, entry #1 willhave a higher priority than entry #4 because usage frequency is used asthe next basis.

Finally, in step S307, the preview window controller 21 sets thethumbnail on the left side that was reordered after being judged to havethe highest priority to a state of being selected as the defaultcandidate. Since the URL of entry #2 furthest to the left is similar tothe URL of the Web page that the user is trying to print, it is all themore likely that the configuration of the Web page and, further, thenaming rules with respect to the Web parts will be similar compared withwhen only the domain name matches. Thus, it can be said that it is alsomore highly likely that the Web page that the user is trying to printwill be converted to a print layout desired by the user, when the stylesheet of entry #2 is applied.

As a result of the processing in the above described steps S301 to S307,it is highly likely that an optimum style sheet will be automaticallyapplied to the Web page that the user is trying to print, furtherenabling to the user's workload to be reduced.

Embodiment 4 FIG. 13 Conceptual View of User Forum Style Sheet DB

Next, a Web page printing apparatus according to an embodiment 4 of thepresent invention will be described using the conceptual view of FIG.13. In embodiments 1 and 2, the style sheet DB 26 that is local to thecomputer 1 was used as a destination for recording style sheetsincluding rearranged layout information and searching for previouslyregistered style sheets. However, since a corresponding style sheet isnot registered unless a Web page is printed by the user, the problemremains of the user not being presented with candidates and having toperform rearrangement, in relation to a Web page that is being visitedfor the first time or a Web page that is being printed for the firsttime.

In view of this, in embodiment 4, a method of presenting print layoutcandidates, by making use of the style sheets of other users stored inthe user forum style sheet DB 27 on the Internet 2, will be discussed.FIG. 13 is a schematic view representing the user forum style sheet DB27 being used by a plurality of users. Note that while referencenumerals such as S401, S402 and S40X will appear in the followingdescription, these are merely to facilitate the description and are notintended to refer to the drawings.

Computers 51, 52, 53 and 54 are computers that are each equipped withthe Web page printing apparatus of the present invention, and a user ofeach computer prints Web pages using the present printing apparatus.These computers are all in a state of being communicable with the userforum style sheet DB 27 via the Internet 2. The user forum style sheetDB 27 is in actual fact a database server, and may have a single serverconfiguration or a configuration extended by a plurality of servers.Also, the format of database records held by the user forum style sheetDB 27 is the same format as the local style sheet DB 26.

In step S121 of embodiments 1 and 2, the style sheet generating unit 22registers the style sheet that was used in the style sheet DB 26 inassociation with the URL of the page that was printed, after printingthe Web page. In the present embodiment, after this S121, the stylesheet generating unit 22 further saves the style sheet in the user forumstyle sheet DB 27 in association with the URL via the network controller101 (step S401). Once processing of this step S401 has been executed aplurality of times in the computer 51, 52 and 53, for example, a largenumber of entries will have been saved to and stored in the user forumstyle sheet DB 27.

Because the users of the computers print various Web pages of variousWeb sites, there will be many kinds of saved URLs and style sheetsassociated with these URLs. Here, next assume that another computer 54has opened the print preview window 31 in order to print a given Webpage. In embodiment 3, style sheets to serve as candidates wereretrieved from only the local style sheet DB 26, but in the presentembodiment, style sheets to serve as candidates are also retrieved fromthe user forum style sheet DB 27.

That is, the style sheet search unit 24 also performs the processingfrom step S205 to S211 for searching the local style sheet DB 26 anddisplaying candidates with regard to the user forum style sheet DB 27,via the network controller 101 (S402). As a result of this processing ofS402, the possibility exists of being able to borrow and use stylesheets created by other users by searching the user forum style sheet DB27, even if style sheets to serve as candidates are not found in thelocal style sheet DB 26. The possibility of finding a style sheet thatcorresponds to the Web page that the user is trying to print with theprocessing of step S402 is small when there are few computers thatperform the registration process of S401, but increases as the number ofcomputers increase to a few dozen, or a few hundreds, or an unspecifiednumber.

In the case where printing has been performed using a style sheetretrieved with the user forum style sheet DB 27, the style sheet searchunit 24 increases by 1 and saves the usage frequency of thecorresponding style sheet via the network controller 101 (step S403).Because a style sheet whose usage frequency is increased by this stepS403 is preferentially displayed on the left side when displayed as acandidate at step S402, the possibility of this style sheet beingfurther used numerous times as a “popular” style sheet increases. Notethat in the case where style sheets to serve as candidates are found inboth the local style sheet DB 26 and the user forum style sheet DB 27 instep S402, various bases are conceivable as a way of reordering thesecandidates. For example, the candidates may simply be reordered on thebasis of usage frequency, or candidates found in the local style sheetDB 26 may be preferentially displayed to the left side of candidatesfound in the user forum style sheet DB 27, even if the usage frequencyis less.

As a result of the above-described processing from steps S401 to S403, alayout suitable for printing can be borrowed and the Web page printed,by utilizing the possibility of there being someone who has performedprinting even if the user himself or herself has not performed printing,enabling the user's workload to be reduced.

Embodiment 5 FIG. 14 Conceptual View of Auto-Layout Function

Next, a Web page printing apparatus according to an embodiment 5 of thepresent invention will be described using FIGS. 14 and 15. In Embodiment4, means for an unspecified number of users being able to retrieve anoptimum style sheet from the user forum style sheet DB 27, even if thereis not a suitable style sheet in the local style sheet DB 26, wasdiscussed. However, in the case where a suitable URL is also notregistered in the user forum style sheet DB 27, that is, in the casewhere the user is trying to print a page that nobody has ever printed,the user will have to rearrange the print layout manually.

In view of this, in embodiment 5, a method of automatically generating alayout suitable for printing from a title given to the Web page, even ifa style sheet registered in a database in advance is not found, will bediscussed.

FIG. 14 is a conceptual view representing an overview of the presentembodiment 5. A title 61 is an example title of a Web page that the useris trying to print. An element <Title/> for deciding the page title isdefined in HTML language. The page title is, as the name suggests, atitle succinctly representing a given Web page, and is normallydisplayed on a title bar or tab sheet of a Web browser, and used as adefault title of a bookmark. Since it is extremely highly likely that akeyword included in this title will have an association with the contentwritten in the body of the Web page, it can be said that there is apossibility of being able to judge a Web part to be printed from thekeyword in the title, and conversely to eliminate unnecessary parts withloose associations.

In view of this, the Web page is searched in relation to termsconstituting the title such as shown in the title 61, and the placeswhere terms appears are counted for each Web part. With the example inFIG. 14, the case is shown where, out of parts 62 to 65, three termsrespectively appear in parts 63 and 64, and none of the terms appear inthe parts 62 and 65. As a result, layout is performed by combining theparts so as to include either or both of the parts 63 and 64, andthumbnails thereof are presented to the user as candidate layouts 66, 67and 68.

It is possible that none of these layouts 66, 67 and 68 will be a layoutthat the user hoped for. However, because there is a good chance ofthere at least being a layout from which Web parts not required inprinting have been eliminated, it is worth choosing this layout as acandidate when an existing style sheet cannot be used. Hereinafter, theprocessing for finalizing the layout automatically as shown in thisconceptual diagram will be described in detail.

FIG. 15: Flow of Auto-Layout Function

FIG. 15 is a flowchart showing processing by the Web page printingapparatus according to embodiment 5. The processing of the presentembodiment is intended to replace steps S205 to S211 of embodiment 2.Alternatively, in embodiment 4, steps S401 and S402 are replaced by FIG.15.

Firstly, in step S501, the preview window controller 21 acquires thetitle from the Web page data. The title is contained in the <Title/>element, as discussed previously.

Next, in step S502, the preview window controller 21 extracts keywordsfrom the title acquired at step S501. As upstream processing of thekeyword extraction, natural language processing is performed to dividethe title into units of terms, in the case where, unlike English, breaksin the terms cannot be mechanically judged, such as when the language ofthe title is Japanese or Chinese. As for the method of extractingkeywords from the terms, various methods are conceivable such aschoosing only proper nouns, or also including common nouns whileexcluding only particles, prepositions and the like. In the presentexample, “weather”, “forecast” and “Tohoku” are treated as keywords,excluding only the preposition “for” from the title 61 shown in FIG. 14.

In the next steps S503 to S505, processing is performed with regard tothe Web parts included in the Web page. In step S503, the preview windowcontroller 21 counts the number of times each of the extracted keywordsappears in the Web page, and derives a total. In the case where a givenkeyword appears a plurality of times, the full number of appearances maybe counted, or the plurality of appearances may only be counted as oneappearance. Also, in the case where proper nouns appear, a singleappearance may be weighted to count for a plurality of appearances. Notethat when searching the HTML data of a Web page, only the actual textcharacters appearing in the window may be set as the search target, ortext and the like contained in ALT attribute data representing notes onthe image data may also be included as the search target.

Next, in step S504, the preview window controller 21 judges whether thetotal counted is one or more, and if one or more, proceeds to S505, andif not one or more, performs no further processing on that part, andagain performs the processing of S503 with regard to the next part. Instep S505, the preview window controller 21 adds the ID of the Web partto the display target ID list. The total number of times each keywordappears in each part is derived by repeating the above steps S503 toS505 in relation to all Web parts, and one or more parts are stored asdisplay targets.

Next, in step S506, the style sheet generating unit 22 extractsarbitrary combinations from the stored one or more display target IDs.Arbitrary combinations indicates three combinations (AB), (A) and (B)when two parts A and B are display targets, and seven combinations(ABC), (AB), (BC), (CA), (A), (B), and (C) when three parts A, B and Care display targets, for example. The number of combinations when nparts are display targets will be 2^(N)−1.

Next, in step S507, the style sheet generating unit 22 chooses a maximumof M candidates that can be displayed in the window in descending orderof the number of parts included therein, from all of the combinationsderived at step S506, and generates corresponding style sheets. When thenumber of candidate thumbnails that can be displayed on the printpreview window 31 is M, the style sheet generating unit 22 chooses Mcombinations in descending order of the number of parts includedtherein, from the combinations of parts. Descending order of the numberof parts included therein means in descending order of the combinationshaving a large number of parts, such as (ABC), (AB) and (BC) in the caseof there being three parts A, B and C, for example. The reason for doingthis is to ensure that as many Web parts in which keywords are locatedare printed as possible. Of course, combinations may be chosen orreordered in accordance with another basis as necessary, such as inascending order of the number of parts.

Next, in step S508, the preview window controller 21 applies the M stylesheets generated in step S507 individually to the Web page that the useris trying to print, and obtains thumbnail images. Finally, in step S509,the preview window display unit 23 displays the candidate thumbnailimages from the left in the print preview window 31 in descending orderof the number of parts included therein, selects the candidate furthestto the left, and displays the selected candidate in the correspondingprint preview image 33.

As a result of the above processing, a print layout approximating theuser's preference can be automatically generated, even in the case wherea suitable style sheet does not exist, enabling the hassle involved indeleting unnecessary parts such as advertisements to be reduced.

Embodiment 6 FIG. 16 Embodiment with Printer Driver

Finally, a Web page printing apparatus according to an embodiment 6 willbe described using FIG. 16. With the aforementioned first to fourthembodiments, the print controller 105 which undertook the coreprocessing of the Web page printing apparatus of the present inventionwas a component incorporated in advance in the Web browser 10 or aplug-in added later. In embodiment 6, the case is shown where a similareffect is obtained even if this print controller is constituted as partof the functions of the printer driver 12.

FIG. 16 is an example in which a print controller is also added as partof the printer driver 12, in addition to the print controller 105 of theWeb browser 10. A private spooler 13 is a component that temporarilysaves rendering commands input to the printer driver 12 in anintermediate format before being converted to PDL. Reference numeral 14is the print controller.

In embodiment 1 to embodiment 5, the print controller 105 receives inputof Web page data to be printed from the page display unit 103 of the Webbrowser 10, whereas the print controller 14 of the present embodimentreceives input of data to be printed from the private spooler 13. Thefact that the print controller 14 communicates via the networkcontroller 101, and performs print output to the graphics engine 11 isunchanged from embodiment 1 to embodiment 5.

Incidentally, with a general printing system, components from theapplications to the printer serving as the output destination form alinear configuration, but with the present embodiment, the graphicsengine 11, the printer driver 12, the private spooler 13 and the printcontroller 14 form a loop configuration. This is to enable the printlayout and print settings to be changed by temporarily holding data tobe printed in the computer, rather than it being output for printing tothe printer 3 immediately after the user has given the instruction forprinting. That is, the intermediate format saved in the private spooler13 via the printer driver 12 is read by the print controller 14, and theuser is able to input an instruction to change the print layout via auser interface displayed by the print controller 14.

Further, the print controller 14 performs layout of the intermediateformat based on an input change instruction, and re-outputs a renderingcommand to the graphics engine 11 again. When re-outputting a renderingcommand from the print controller 14, information instructing that thisis the “second round of printing” is included in the rendering command,so that the processing does not loop endlessly.

Here, in order to rearrange a print layout, which is a main focus of thepresent invention, in the print controller 14, the intermediate formatsaved in the private spooler 13 needs to be converted to HTML format,which is an actual Web page, or a format approaching HTML format. As anexample, EMF (Enhanced Meta File) format conventionally used withMicrosoft Windows®, being a primitive format specifically designed forrendering, is not suited, but XPS (XML Paper Specification) supported byWindows Vista® is suitable. With the XPS format, the renderinginformation of a page is written in XML markup, and much informationapart from rendering information can also be represented. For example,it is possible to define parts constituting a Web page by hierarchizingXML markups and compiling a number of pieces of rendering information,and to also define layout information relating to each part separatelyfrom page information. Further, URL information on Web pages that isnecessary in the present invention and page title information can alsobe defined in XPS data.

As discussed above, even in a printing system such as shown in FIG. 16,a Web page printing apparatus of the present invention can be configuredby selecting HTML format or a format equivalent thereto as anintermediate format to be temporality saved.

Other Embodiments

Aspects of the present invention can also be realized by a computer of asystem or apparatus (or devices such as a CPU or MPU) that reads out andexecutes a program recorded on a memory apparatus to perform thefunctions of the above-described embodiments, and by a method, the stepsof which are performed by a computer of a system or apparatus by, forexample, reading out and executing a program recorded on a memoryapparatus to perform the functions of the above-described embodiments.For this purpose, the program is provided to the computer for examplevia a network or from a recording medium of various types serving as thememory apparatus (e.g., computer-readable medium).

While the present invention has been described with reference toexemplary embodiments, it is to be understood that the invention is notlimited to the disclosed exemplary embodiments. The scope of thefollowing claims is to be accorded the broadest interpretation so as toencompass all such modifications and equivalent structures andfunctions.

This application claims the benefit of Japanese Patent Application No.2009-022963, filed Feb. 3, 2009, which is hereby incorporated byreference herein in its entirety.

1. An information processing apparatus for printing a Web pageconstituted by a plurality of parts, comprising: a selecting unit,configured to select a part to be printed from parts constituting a Webpage targeted for printing; a creating unit, configured to create astyle sheet for printing on which the part selected by the selectingunit has been rearranged; a storage unit, configured to store the stylesheet in association with an address of the print target Web page; anextracting unit, configured to, in a case where a Web page newlytargeted for printing is displayed, extract a style sheet to be used forthe new Web page from one or more style sheets stored by the storageunit, based on an address of the new Web page; and a generating unit,configured to generate a print page based on the style sheet extractedby the extracting unit and the new Web page.
 2. The informationprocessing apparatus according to claim 1, wherein the extracting unitextracts a style sheet associated with an address of which at least aportion indicating a server matches the address of the new Web page. 3.The information processing apparatus according to claim 1, furthercomprising: a display unit, configured to display the print pagegenerated by the generating unit, wherein the storage unit furtherstores a frequency with which printing has been performed using thestyle sheet, in association with the style sheet and the address of theprint target Web page, and the display unit, in a case where a pluralityof style sheets are extracted by the extracting unit, displays aplurality of print pages generated from the plurality of style sheetsand the new Web page, in order of the usage frequency.
 4. A method of aninformation processing apparatus for printing a Web page constituted bya plurality of parts, said method comprising: a selecting step ofselecting a part to be printed from parts constituting a Web pagetargeted for printing; a creating step of creating a style sheet forprinting on which the part selected in the selecting step has beenrearranged; a storage step of storing the style sheet in associationwith an address of the print target Web page; an extracting step of, ina case where a Web page newly targeted for printing is displayed,extracting a style sheet to be used for the new Web page from one ormore style sheets stored in the storage step, based on an address of thenew Web page; and a generating step of generating a print page based onthe style sheet extracted in the extracting step and the new Web page.5. The method according to claim 4, wherein in the extracting step astyle sheet is extracted which is associated with an address of which atleast a portion indicating a server matches the address of the new Webpage.
 6. The method according to claim 4, further comprising: a displaystep of displaying the print page generated in the generating step,wherein in the storage step a frequency is further stored with whichprinting has been performed using the style sheet, in association withthe style sheet and the address of the print target Web page, and thedisplay step of, in a case where a plurality of style sheets areextracted in the extracting step, displaying a plurality of print pagesgenerated from the plurality of style sheets and the new Web page, inorder of the usage frequency.
 7. A computer readable medium storing aprogram thereon, a computer performs by executing the program a methodof an information processing apparatus for printing a Web pageconstituted by a plurality of parts, said method comprising: a selectingstep of selecting a part to be printed from parts constituting a Webpage targeted for printing; a creating step of creating a style sheetfor printing on which the part selected in the selecting step has beenrearranged; a storage step of storing the style sheet in associationwith an address of the print target Web page; an extracting step of, ina case where a Web page newly targeted for printing is displayed,extracting a style sheet to be used for the new Web page from one ormore style sheets stored in the storage step, based on an address of thenew Web page; and a generating step of generating a print page based onthe style sheet extracted in the extracting step and the new Web page.8. The medium according to claim 7, wherein in the extracting step astyle sheet is extracted which is associated with an address of which atleast a portion indicating a server matches the address of the new Webpage.
 9. The medium according to claim 7, wherein said method furthercomprising: a display step of displaying the print page generated in thegenerating step, and wherein in the storage step a frequency is furtherstored with which printing has been performed using the style sheet, inassociation with the style sheet and the address of the print target Webpage, and the display step of, in a case where a plurality of stylesheets are extracted in the extracting step, displaying a plurality ofprint pages generated from the plurality of style sheets and the new Webpage, in order of the usage frequency.